Fix which-key--create-pages
authorJustin Burkett <justin@burkett.cc>
Wed, 28 Feb 2018 13:03:16 +0000 (08:03 -0500)
committerJustin Burkett <justin@burkett.cc>
Wed, 28 Feb 2018 13:07:27 +0000 (08:07 -0500)
which-key.el

index ba6bc454c1a43e58346c89cd05a10be6a624ad7c..a6a4c3ebc895433f3d1228d78bff4b1e75fcf67a 100644 (file)
@@ -1944,7 +1944,8 @@ is the width of the live window."
     (setq result
           (which-key--create-pages-1
            keys avl-lines avl-width min-lines vertical))
-    (when (> (which-key--pages-num-pages result) 0)
+    (when (and result
+               (> (which-key--pages-num-pages result) 0))
       (setf (which-key--pages-prefix result) prefix-keys)
       (setf (which-key--pages-prefix-title result)
             (or prefix-title